//获取express对象
var express=require("express"),
	app=express(),
	http=require("http"),
	dirname=__dirname.substring(0,__dirname.length-7);
//创建静态路径
app.use(express.static("../../app"));
//在页面一加载开始的时候出现主页
app.get("/",function(req,res){
	res.sendFile(dirname+"/index.html");
}).get("/json",function(req,res){
	res.sendFile(dirname+"/data/index/banner.json");
}).get("/jsonTwn",function(req,res){
	res.sendFile(dirname+"/data/index/menu.json");
}).get("/freeWalk",function(req,res){
	res.sendFile(dirname+"/data/index/freeWalk.json");
}).get("/cityWalk",function(req,res){
	res.sendFile(dirname+"/data/citywalk/cityWalkList.json");
}).get("/cityWalkPage",function(req,res){
	res.sendFile(dirname+"/cityWalkPage.html");
}).get("/cityWalkPage/json",function(req,res){
	res.sendFile(dirname+"/data/index/cityWalk.json");
}).listen(8080,function(){
	console.log(dirname);
})










